Properties are containers for different types of values with a common interface. This interface enables you to use properties in several places, such as scene graph and materials. For example, Kanzi provides all material values, including shader uniforms, as properties.
In Kanzi properties are formed using two structures: property and property type. Property type defines what the property is like, including name, data type, and default value, while property defines a value. Each property is linked to a corresponding property type. Most of the property implementations are containers for basic primitives or structures, such as Booleans, floats, colors, and vectors, but can include other information too.
Kanzi Studio allows the modification of project content by:
When a property value is changed in Properties or in the Preview using the edit tools, you can see the result in the Preview. The values in the Properties are the edit values. The values of these properties can change during the application runtime as a result of user actions, animations, or using other mechanisms. The Preview uses the runtime values, but the Properties and Project do not. The same applies to instancing nodes during runtime.
To restore the Preview to the initial values, restart the Preview by selecting Project > Restart Preview. Note that the original values visible in the Preview can still differ from the edited local values in the Properties in case the value is being overwritten by for example bindings or application code specific behavior..
Properties can receive values from different sources. Kanzi Engine resolves the runtime values based on the following precedence rules (highest first):
In a Kanzi Studio project objects are organized into a tree hierarchy and child objects inherit property values from their parent object. This applies properties of most objects, but not all.
For example, a Text Block object inherits the value of the Font property, but not the value of the Text property. You can set the Font property on any root object that is a common ancestor to all Text Block object in a scene, and so make it the default font for all Text Block object in your Kanzi application. However, you cannot set a default Text property value for all text blocks because the Text property value is not inheritable. Note that the object that owns the Text property does not need to be a text block.
In addition to the basic inheritance, materials use a concept called virtual inheritance, which allows them to inherit properties from the objects that they are attached to. For example, you can add a texture as a property to a mesh object, rather than to the material.
Certain properties are propagated instead of inherited. For example, Kanzi multiplies a child object’s transformation to the parent object’s transformation.
You can use profiles for creating multiple versions of the same project. You can set different property values for each profile and when exporting the .kzb binary, Kanzi creates a binary for each profile with the corresponding values.
For example, using profiles you can configure your Kanzi application for different screen sizes in the screen object's Window property group. See Profiles.